Skip to content

Move jobs within the experiment folder and make calls faster#1607

Merged
deep1401 merged 32 commits intomainfrom
fix/jobs-list-fetcher
Mar 25, 2026
Merged

Move jobs within the experiment folder and make calls faster#1607
deep1401 merged 32 commits intomainfrom
fix/jobs-list-fetcher

Conversation

@deep1401
Copy link
Copy Markdown
Member

@deep1401 deep1401 commented Mar 23, 2026

No description provided.

@deep1401 deep1401 changed the title Fix/jobs list fetcher Move jobs within the experiment folder and make calls faster Mar 23, 2026
@deep1401 deep1401 marked this pull request as ready for review March 23, 2026 16:36
Copy link
Copy Markdown
Member

@dadmobile dadmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Havne't tested yet. But found some things with job_get that might cause issues?

if not resolved_job_id:
return None

key = _job_cache_key(resolved_job_id)
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just calling this out as I'm not 100% I'm following...
In the get function this makes sure to resolve the job_id to to the full value but in job_update_status it uses the passed job_id, which I'm not sure if it will definitely be the resolved full ID or not?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It wont get to that case because I think we use full ids everywhere for cache writes and the read comes through Job.get which would need the full id so there wont be duplicated cache entries?

Disable auto-migration when `TFL_DISABLE_MIGRATE_JOBS=1` (or true-ish).

Also supports a legacy/alternative value:
- `TFL_DISABLE_MIGRATE=jobs`
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Did this exist before?!?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It didnt exist before but I just added it as a dev thing incase someone wanted to use. Should I get rid of it?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I meant that for some reason there are two variables? TFL_DISABLE_MIGRATE_JOB and TFL_DISABLE_MIGRATE?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its only 1. The comment is wrong. I'll fix. I'll actually just remove the variable altogether, we dont need it now. It was only for me

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

removed

Copy link
Copy Markdown
Member

@dadmobile dadmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got this (NaN) while trying to view files? In case it matters the job failed (with the error I sent you) and confirmed in the network bar that it was trying to call http://localhost:8338/experiment/AWStest/jobs/NaN/files?subpath=:

Image

@dadmobile
Copy link
Copy Markdown
Member

(Also same issue for provider logs as for file browser)

Copy link
Copy Markdown
Member Author

@deep1401 deep1401 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I got this (NaN) while trying to view files? In case it matters the job failed (with the error I sent you) and confirmed in the network bar that it was trying to call http://localhost:8338/experiment/AWStest/jobs/NaN/files?subpath=:

There were multiple parseInt(jobid) calls in the frontend. I fixed all of them. It should be fixed now, could check once more for the same job please?

@deep1401 deep1401 requested review from dadmobile March 24, 2026 18:59
Copy link
Copy Markdown
Member

@dadmobile dadmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like it is putting my old jobs at the top of the job history list?

Image

@deep1401
Copy link
Copy Markdown
Member Author

It seems like it is putting my old jobs at the top of the job history list?

Image

I think thats probably because it tries to sort by id first, will fix

Copy link
Copy Markdown
Member Author

@deep1401 deep1401 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like it is putting my old jobs at the top of the job history list?

Okay so I fixed the sorting now and its two-fold. Jobs are sorted by either of created_at or started_at fields

Copy link
Copy Markdown
Member

@dadmobile dadmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Temporarily rescinding approval while I try to figure out a better way to do the migration (or I don't and we just move forward).

Copy link
Copy Markdown
Member

@dadmobile dadmobile left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Reviewed with team. G2G.

@deep1401 deep1401 merged commit c9caf2a into main Mar 25, 2026
12 of 13 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants